package design_pattern.FactoryModel2;

import design_pattern.FactoryModel2.Factory.Factory;
import design_pattern.FactoryModel2.Product.Product;

/**
 * @Description
 * @Author yangshunjie
 * @Date 2021/9/20
 */
public class Comsumer {
    Factory factory ;
    public Comsumer(Factory factory) {
        this.factory = factory;
    }

    public Product getProduct(){
        Product product = factory.getProduct();
        return product;
    }
}
